home *** CD-ROM | disk | FTP | other *** search
/ QRZ! Ham Radio 8 / QRZ Ham Radio Callsign Database - Volume 8.iso / pc / files / mac / sftkisrc.hqx / SoftKiss.src.1.8 / dbo / dbo_test.c < prev    next >
C/C++ Source or Header  |  1992-05-06  |  1KB  |  46 lines

  1. /*
  2.  * dbo_test.c - test interupt level debugging output
  3.  */
  4.  
  5. #include <stdio.h>
  6. #include <console.h>
  7.  
  8. #include "dbo_stdio.h"
  9.  
  10. /*
  11.  * loop to test drawing characters on the screen
  12.  */
  13. static void dbo_test()
  14. {
  15.     dbo_FILE af;
  16.     char ch;
  17.     char buf[100];
  18.     dbo_fopen(&af);
  19.     /*window is in upper left quater of screen*/
  20.     af.win_tl.h=8;
  21.     af.win_tl.v=10;
  22.     af.win_cur=af.win_tl;    /*start writeing in window*/
  23.     af.win_br.h=200;
  24.     af.win_br.v/=2;
  25.     dbo_fclear(&af);
  26.  
  27.     while(TRUE) {
  28.         fgets(buf,sizeof(buf),stdin);
  29. //        dbo_fputc(&af,ch);
  30.         dbo_fprintf(&af,"abcdefghijklmnopqrstuvwxyz`~!@#$%^&*()[]\\;',./{}|:<>?\n");
  31. //        dbo_fprintf(&af,"ABCDEFGHIJKLMNOPQRSTUVWXYZ`~!@#$%^&*()[]\\;',./{}|:<>?\n");
  32.         af.wrap=FALSE;
  33.         dbo_fprintf(&af,"'%5d' '%5ld' %04ld '%-4ld' %s %#s\n",-1,-1000L,23L,25L,"hi","\pPHI");
  34.         dbo_fprintf(&af,"Hi %d %ld %x %lx %c\n",1,2L,0x8081,0x12345L,'g');
  35.         af.wrap=TRUE;
  36.     }
  37. }
  38.  
  39. int main()
  40. {
  41.   console_options.left=40;
  42.   console_options.ncols=40;
  43.   printf("dbo_test test client test jig built on %s %s\n",__DATE__,__TIME__);
  44.   dbo_test();
  45. }
  46.